<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<style>
    div{
        width: 800px;
        height: 40px;
        margin: 0 auto;
        display: flex;
        background-color: #999;
        padding: 5px;
    }

    div span{
        width: 100px;
        height: 40px;
        text-align: center;
        line-height: 40px;
        background-color: pink;
        color:#fff;
    }
    
    div span:nth-child(2){
        flex:1;
        background-color: blue;
    }
</style>
<body>
    <div>
        <span>左侧</span>
        <span>中间</span>
        <span>右侧</span>
    </div>
</body>
</html>